extends ../layouts/basic

block extra_head

    <title>下载 - Apache ECharts (incubating)</title>
    script(src="#{cdnRoot}/#{ecWWWLang}/vendors/sweetalert.js")

block content
    nav(class='navbar navbar-default navbar-fixed-top')
        include ./nav

    block vars

    .page-info
        h1 下载

    .page-content.container#download-main
        .d-section-version.d-section

            h3.first 方法一：从下载的源代码或编译产物安装

            table.table#download-table
                tr
                    th 版本
                    th 发布日期
                    th 从镜像网站下载源码
                    th 从 GitHub 下载编译产物

            .checksum
                p <strong>注意：</strong>如果从镜像网站下载，请检查 <a href="https://www.apache.org/dev/release-signing#sha-checksum">SHA-512</a> 并且检验确认 <a href="https://www.apache.org/dev/release-signing#openpgp">OpenPGP</a> 与 <a href="https://www.apache.org">Apache 主站</a>的签名一致。链接在上面的 Source 旁。这个 <a href="https://www.apache.org/dist/incubator/echarts/KEYS">KEYS</a> 文件包含了用于签名发布版的公钥。如果可能的话，建议使用<a href="https://www.apache.org/dev/release-signing#web-of-trust">可信任的网络（web of trust）</a>确认 KEYS 的同一性。

                h4 使用 GPG 验证 ECharts 发布版本
                ol
                    li 从镜像网站下载 apache-echarts-X.Y.Z-incubating-src.zip
                    li 从 <a href="https://www.apache.org/dist/incubator/echarts/">Apache</a> 下载 checksum apache-echarts-X.Y.Z-incubating-src.zip.asc
                    li 下载 <a href="https://www.apache.org/dist/incubator/echarts/KEYS">ECharts KEYS</a>
                    li gpg –import KEYS
                    li gpg –verify apache-echarts-X.Y.Z-incubating-src.zip.asc

                h4 使用 SHA-512 验证
                ol
                    li 从镜像网站下载 apache-echarts-X.Y.Z-incubating-src.zip
                    li 从 <a href="https://www.apache.org/dist/incubator/echarts/">Apache</a> 下载 checksum apache-echarts-X.Y.Z-incubating-src.zip.sha512
                    li shasum -a 512 apache-echarts-X.Y.Z-incubating-src.zip

                h4 License
                p Apache ECharts (incubating) 基于 <a href="https://www.apache.org/licenses/LICENSE-2.0">Apache License 2.0</a> 发布

            //- if isECharts4
            //-     h3 （前往下载 <a href="download3.html">3.x 版本）</a>
            //- else
            //-     h3 （前往下载 <a href="download.html">4.x 版本）</a>

            //- h3 选择需要的版本 <span class="warn">注：开发环境建议选择源代码版本，该版本包含了常见的警告和错误提示。</span>

            //- .list-wrap.row#download-row
            //-     .col-sm-3.col-xs-6
            //-         a(class="download-echarts" href="#{downloadPath}/echarts.common.min.js" download="echarts.common.min.js")
            //-             .circle-wrap
            //-                 span.mode 常用
            //-                 span.size #{sizeCommon}
            //-         .text 包含常用的图表组件<br><span>折 柱 饼 散点 图例<br />工具栏 标注/线/域<br /> 数据区域缩放</span>
            //-     .col-sm-3.col-xs-6
            //-         a(class="download-echarts" href="#{downloadPath}/echarts.simple.min.js" download="echarts.simple.min.js")
            //-             .circle-wrap
            //-                 span.mode 精简
            //-                 span.size #{sizeSimple}
            //-         .text 只包含基础图表<br><span>折 柱 饼</span>
            //-     .col-sm-3.col-xs-6
            //-         a(class="download-echarts" href="#{downloadPath}/echarts.min.js" download="echarts.min.js")
            //-             .circle-wrap
            //-                 span.mode 完整
            //-                 span.size #{sizeMin}
            //-         .text 包含所有图表组件
            //-     .col-sm-3.col-xs-6
            //-         a(class="download-echarts" href="#{downloadPath}/echarts.js" download="echarts.js")
            //-             .circle-wrap
            //-                 span.mode 源代码
            //-                 span.size #{sizeFull}
            //-         .text 包含所有图表组件<br />的源码，常见的警告和错误提示

            //- div(class="download-note") <i class="note-icon"><img src="./images/note.svg" /></i> Please cite the following paper whenever you use ECharts in your R&D projects, products, research papers, technical reports, news reports, books, presentations, teaching, patents, and other related intelligence activities. <br />  当您在研发项目，研究论文，技术报告，新闻报告，书籍，演示文稿，教学，专利等中使用 ECharts 时，请引用以下论文。
            //- div(class="paper-desc")
            //-     a(href="http://www.cad.zju.edu.cn/home/vagblog/VAG_Work/echarts.pdf") ECharts: A Declarative Framework for Rapid Construction of Web-based Visualization

            h3 方法二：从 npm 安装
            p <code>npm install echarts</code>

            h3 方法三：选择需要的模块，在线定制下载

            if isECharts4
                a.btn.btn-thirdary.more-btn(href="builder.html") 在线定制
            else
                a.btn.btn-thirdary.more-btn(href="builder3.html") 在线定制
            p.center 可自由选择所需图表和组件进行打包下载

            h3 下载后……
            p
                a(href='./tutorial.html') 5 分钟上手 ECharts

        .d-section-gl.d-section
            h2 下载 ECharts GL 1.1.1
            p ECharts GL 是 WebGL 的扩展包，提供了丰富的三维可视化组件以及常规图表的性能增强。
            h4 选择需要的版本 <span class="warn">注：开发环境建议选择源代码版本，该版本包含了常见的警告和错误提示。</span>
            .list-wrap.row
                .col-xs-6.col-sm-3.col-sm-offset-3
                    a(target='_blank' href="#{downloadPath}/echarts-gl.min.js")
                        .circle-wrap
                            span.mode 压缩版
                            span.size 637 KB
                .col-xs-6.col-sm-3
                    a(target='_blank' href="#{downloadPath}/echarts-gl.js")
                        .circle-wrap
                            span.mode 源代码
                            span.size 1.74 MB
            a.btn.btn-thirdary.btn-two(href="#{host}/#{ecWWWLang}/option-gl.html") 查看 GL 文档
            a.btn.btn-thirdary.btn-two(href="#{host}/examples/#{ecWWWLang}/index.html#chart-type-globe") 查看 GL 实例

        //- .d-section-theme.d-section
        //-     h2 主题
        //-     p 让你的图表整体换个装，除了官方提供的主题之外，还可以定制你自己的主题
        //-     .list-wrap.row
        //-         .col-md-4.col-md-offset-2.col-sm-6
        //-             a(href="asset/theme/vintage.js" class="download-theme" download="vintage.js" target="_blank")
        //-                 img(src="asset/theme/thumb/vintage.png")
        //-             p 复古主题
        //-         .col-md-4.col-sm-6
        //-             a(href="asset/theme/dark.js" class="download-theme" download="dark.js" target="_blank")
        //-                 img(src="asset/theme/thumb/dark.png")
        //-             p 深色主题
        //-     a.btn.btn-thirdary.more-btn(href="download-theme.html") 更多主题

        //- .d-section-map.d-section
        //-     h2 地图数据
        //-     p 提供世界、中国、各省地图，数据来自第三方
        //-     .list-wrap.row
        //-         .col-md-4.col-md-offset-2.col-sm-6
        //-             a(href="asset/map/json/china.json" download="china.json" target="_blank")
        //-                 img.hover-shadow(src="asset/map/thumb/china.png")
        //-             p 中国地图
        //-         .col-md-4.col-sm-6
        //-             a(href="asset/map/json/world.json" download="world.json" target="_blank")
        //-                 img.hover-shadow(src="asset/map/thumb/world.png")
        //-             p 世界地图
        //-     a.btn.btn-thirdary.more-btn(href="download-map.html") 更多地图

    //- #download-extension-container.container
    //-     .d-section-extension.d-section.last-section
    //-         h2 扩展
    //-         p 提供更丰富的图表类型和增强功能
    //-         .list-wrap.row
    //-             .col-sm-4
    //-                 a(href="https://github.com/ecomfe/echarts-wordcloud")
    //-                     img.hover-shadow(src="images/extensions/word-cloud.jpg")
    //-                 p 字符云
    //-             .col-sm-4
    //-                 a(href="https://github.com/ecomfe/echarts-liquidfill")
    //-                     img.hover-shadow(src="images/extensions/liquidfill.jpg")
    //-                 p 水球图插件
    //-             .col-sm-4
    //-                 a(href="https://github.com/ecomfe/echarts/tree/master/extension/bmap")
    //-                     img.hover-shadow(src="images/extensions/bmap.jpg")
    //-                 p 百度地图
    //-         a.btn.btn-thirdary.more-btn(href="download-extension.html") 更多插件

    include ./footer


block extra_js
    script(src="#{cdnRoot}/#{ecWWWLang}/js/download.js?_v_=#{homeVersion}")
    script(type='text/javascript').
        document.getElementById('nav-download').className = 'active';

        //- $('.download-echarts').click(function (e) {
        //-     var el = document.createElement('div');
        //-     el.innerHTML = '<div class="download-note"><i class="note-icon"><img src="./images/note.svg" /></i> Please cite the following paper whenever you use ECharts in your R&D projects, products, research papers, technical reports, news reports, books, presentations, teaching, patents, and other related intelligence activities. <br />  当您在研发项目，研究论文，技术报告，新闻报告，书籍，演示文稿，教学，专利等中使用 ECharts 时，请引用以下论文。</div>\
        //-     <div class="paper-desc">\
        //-         <div class="paper-title">\
        //-         ECharts: A Declarative Framework for Rapid Construction of Web-based Visualization\
        //-         </div>\
        //-         <div class="paper-author">Deqing Li, Honghui Mei, Yi Shen, Shuang Su, Wenli Zhang, Junting Wang, Ming Zu, Wei Chen.</div>\
        //-         <div class="paper-journal">Visual Informatics, 2018 <a href="http://www.cad.zju.edu.cn/home/vagblog/VAG_Work/echarts.pdf">[PDF]</a></div>\
        //-     </div>';
        //-     swal({
        //-         title: 'Notice',
        //-         content: el
        //-     });
        //-     _hmt.push(['_trackEvent', 'download', 'download', '#{downloadVersion}']);
        //- });
        //- $('.download-theme').click(function () {
        //-     _hmt.push(['_trackEvent', 'download', 'download-theme', '#{downloadVersion}']);
        //- });
